package perso.marcr.lst.service;

import java.text.ParseException;
import java.util.List;

import org.quartz.SchedulerException;

import perso.marcr.lst.model.TaskList;

public interface CronService {

	/**
	 * @param jobName
	 * @param cronExpression
	 * @throws SchedulerException
	 * @throws ParseException 
	 */
	void updateCron(String jobName, String cronExpression) throws SchedulerException, ParseException;

	/**
	 * @param jobName
	 * @throws SchedulerException 
	 */
	void removeFromCron(String jobName) throws SchedulerException;

	/**
	 * @return
	 * @throws SchedulerException
	 */
	List<TaskList> getCurrentlyExecutingJobs() throws SchedulerException;


	/**
	 * @return
	 * @throws SchedulerException
	 */
	List<TaskList> getPendingJobs() throws SchedulerException;

	/**
	 * @param szJobName
	 * @throws SchedulerException 
	 */
	void fireNow(String szJobName) throws SchedulerException;


}
